//  this library.
enum CollectionTypeEnum {
  chapter(desc: "章节"),
  paper(desc: "试卷"),
  everyDayPractice(desc: "每日一练"),
  rankError(desc: "高频错题"),
  rankCollect(desc: "收藏排行"),
  hotQue(desc: "热门试题"),
  ;

  final String desc;

  const CollectionTypeEnum({
    required this.desc,
  });

  static CollectionTypeEnum? getTypeEnum(String type) {
    var values = CollectionTypeEnum.values;
    for (var value in values) {
      if (value.name == type) {
        return value;
      }
    }
    return null;
  }
}
